#include "in.h"

#include "rbtree_tpl.h"

LINK_RBTREENODE_STRING( LinkStoreNameTreeNode , struct MQBroker , store_name_tree , struct MQStore , store_name_tree_node , store_name )
UNLINK_RBTREENODE( UnlinkStoreNameTreeNode , struct MQBroker , store_name_tree , struct MQStore , store_name_tree_node )
QUERY_RBTREENODE_STRING_WITH_LEN( QueryStoreNameWithLenTreeNode , struct MQBroker , store_name_tree , struct MQStore , store_name_tree_node , store_name , store_name_len )
TRAVEL_RBTREENODE( TravelStoreNameTreeNode , struct MQBroker , store_name_tree , struct MQStore , store_name_tree_node )
DESTROY_RBTREE( DestroyStoreNameTree , struct MQBroker , store_name_tree , struct MQStore , store_name_tree_node , NULL )

LINK_RBTREENODE_STRING( LinkTopicNameTreeNode , struct MQStore , topic_name_tree , struct MQTopic , topic_name_tree_node , topic_name )
UNLINK_RBTREENODE( UnlinkTopicNameTreeNode , struct MQStore , topic_name_tree , struct MQTopic , topic_name_tree_node )
QUERY_RBTREENODE_STRING_WITH_LEN( QueryTopicNameWithLenTreeNode , struct MQStore , topic_name_tree , struct MQTopic , topic_name_tree_node , topic_name , topic_name_len )
TRAVEL_RBTREENODE( TravelTopicNameTreeNode , struct MQStore , topic_name_tree , struct MQTopic , topic_name_tree_node )
DESTROY_RBTREE( DestroyTopicNameTree , struct MQStore , topic_name_tree , struct MQTopic , topic_name_tree_node , NULL )

LINK_RBTREENODE_STRING( LinkSubscribeGroupNameTreeNode , struct MQTopic , subscribe_group_name_tree , struct MQSubscribeGroup , subscribe_group_name_tree_node , subscribe_group_name )
UNLINK_RBTREENODE( UnlinkSubscribeGroupNameTreeNode , struct MQTopic , subscribe_group_name_tree , struct MQSubscribeGroup , subscribe_group_name_tree_node )
QUERY_RBTREENODE_STRING_WITH_LEN( QuerySubscribeGroupNameWithLenTreeNode , struct MQTopic , subscribe_group_name_tree , struct MQSubscribeGroup , subscribe_group_name_tree_node , subscribe_group_name , subscribe_group_name_len )
TRAVEL_RBTREENODE( TravelSubscribeGroupNameTreeNode , struct MQTopic , subscribe_group_name_tree , struct MQSubscribeGroup , subscribe_group_name_tree_node )
DESTROY_RBTREE( DestroySubscribeGroupNameTree , struct MQTopic , subscribe_group_name_tree , struct MQSubscribeGroup , subscribe_group_name_tree_node , NULL )

LINK_RBTREENODE_INT( LinkDelayMessageOffsetTreeNode , struct MQStore , delay_msg_offset_tree , struct MQDelayMessage , delay_msg_offset_tree_node , delay_msg_offset )
UNLINK_RBTREENODE( UnlinkDelayMessageOffsetTreeNode , struct MQStore , delay_msg_offset_tree , struct MQDelayMessage , delay_msg_offset_tree_node )
QUERY_RBTREENODE_INT( QueryDelayMessageOffsetTreeNode , struct MQStore , delay_msg_offset_tree , struct MQDelayMessage , delay_msg_offset_tree_node , delay_msg_offset )
DESTROY_RBTREE( DestroyDelayMessageOffsetTree , struct MQStore , delay_msg_offset_tree , struct MQDelayMessage , delay_msg_offset_tree_node , NULL )

LINK_RBTREENODE_INT_ALLOWDUPLICATE( LinkDelayMessageSendTimestampTreeNode , struct MQStore , delay_msg_send_timestamp_tree , struct MQDelayMessage , delay_msg_send_timestamp_tree_node , delay_seconds )
UNLINK_RBTREENODE( UnlinkDelayMessageSendTimestampTreeNode , struct MQStore , delay_msg_send_timestamp_tree , struct MQDelayMessage , delay_msg_send_timestamp_tree_node )
TRAVEL_RBTREENODE( TravelDelayMessageSendTimestampTreeNode , struct MQStore , delay_msg_send_timestamp_tree , struct MQDelayMessage , delay_msg_send_timestamp_tree_node )

